<%= form_for @user do |f| %>
    <p>
      <%= f.label :username %><br>
      <%= f.text_field :username, :size => 20, :min => 5, :max => 30 %>
    </p>

    <p>
      <%= f.label :password %><br>
      <%= f.password_field :password, :size => 20, :min => 6, :max => 30 %>
    </p>

    <p>
      <%= f.label :email %><br>
      <%= f.text_field :email, :size => 20, :min => 6 %>
    </p>
    <p>
      <%= f.hidden_field :id %>
      <%= f.hidden_field :status %>
      <%= f.hidden_field :version %>
    </p>


    <p>
      <%= f.submit %>
    </p>

    <% if @user.errors.any? %>
        <div id="error_explanation">
          <h2>
            <% pluralize(@user.errors.count, "error") %> prohibited
            this user from being saved:</h2>
          <ul>
            <% @user.errors.full_messages.each do |msg| %>
                <li><%= msg %></li>
            <% end %>
          </ul>
        </div>
        <p>
          <%= @user.errors.inspect %>
        </p>
    <% end %>



<% end %>